<template>
  <div class="app-container">
    <el-tabs v-model="currentTabName" @tab-click="handleClick">
      <el-tab-pane label="聊天记录" name="List">
        <List v-if="currentTabName === 'List'" />
      </el-tab-pane>
      <el-tab-pane v-if="checkPermission(permissionRoles.blockword)" label="屏蔽词库" name="BlockWord">
        <BlockWord v-if="currentTabName === 'BlockWord'" />
      </el-tab-pane>
      <!-- <el-tab-pane label="无感词库" name="NumbWord">
        <NumbWord v-if="currentTabName === 'NumbWord'" />
      </el-tab-pane> -->
    </el-tabs>
  </div>
</template>
<script>
import checkPermission from '@/utils/permission'
import List from './components/list'
import BlockWord from './components/blockword'
import NumbWord from './components/numbword'
export default {
  name: 'Log',
  components: { List, BlockWord, NumbWord },
  data() {
    return {
      permissionRoles: this.$store.state.user.permissionRoles,
      currentTabName: 'List'
    }
  },
  methods: {
    checkPermission,
    handleClick() {
    }
  }
}
</script>
